#include "tree.hpp"
#include <cstdio>

void TreeTest() {
  // TreeNodeInOrder<int> t[MaxSize]; // 顺序存储
  BiTree<int> root = nullptr;
  root = (BiTree<int>)malloc(sizeof(BiTNode<int>));
  root->data = {1};
  // root->lchild = nullptr;
  // root->rchild = nullptr;
  BiTNode<int> *p = (BiTNode<int> *)malloc(sizeof(BiTNode<int>));
  p->data = {2};
  p->lchild = nullptr;
  p->rchild = nullptr;
  root->lchild = p;
  p = (BiTNode<int> *)malloc(sizeof(BiTNode<int>));
  p->data = 3;
  root->rchild = p;
  p = (BiTNode<int> *)malloc(sizeof(BiTNode<int>));
  p->data = 6;
  root->rchild->rchild = p;
  printf("root:%d, left:%d\n", root->data, root->lchild->data);
  LevelOrder(root);
}



int main(){
  // TreeTest();
}